{% extends "layout_backend.html" %}

{% block header %}
<h1>Amdin Panel - business</h1>
{% end %}

{% block script %}
<script type="text/javascript">
  var tags = new Array();
  var bi = Object();
  bi.delete = function(id){
  if(id>0 && confirm("你确定要删除该菜品？(相关图片、评分、介绍)")){
  $.post("/business/items/del",{iid:id},function(data){
  alert(data);
  });
  }
  };
</script>
{% end %}

{% block nav %}
<nav class="clearfix">
  <a href="/business/items">菜品</a>
  <a href="/business/order">订单</a>
  <a href="/business/rate">评分</a>
  <a href="/business/report">报表</a>
  <a href="/business/setting">设置</a>
  <a href="/logout">退出</a>
</nav>
{% end %}

{% block content %}
<div class="tag clearfix">
  <a href="/business/items">添加</a> <a href="/business/items/list">菜单</a> <a href="/business/items/trash">回收站</a>
</div>

<div class="c1 clearfix">
{% for item in val['items'] %}
<div class="i1">
  <table width="100%" cellspacing="0" cellpadding="0" border="0">
	<tr>
	  <td class="title">{{ item.name }}</td>
	</tr>
	<tr>
	  <td height="150"><img src="/static/attachments/thumb_{{ item.ename }}" /></td>
	</tr>
	<tr>
	  <td class="tag">
		<a href="javascript:bi.delete({{ item.id }})" style="background:#930">删除</a> 
		<a href="#">修改</a> 
		<a href="#">统计</a>
		<a href="#">评分</a>
	  </td>
	</tr>
	<tr>
	  <td>star</td>
	</tr>
  </table>
</div>
{% end %}
</div>
{% end %}


